FROM localhost:5000/docker-hadoop-base:v2.7.6
MAINTAINER bdcn <bdcnlink@163.com>

HEALTHCHECK CMD curl -f http://localhost:50070/ || exit 1

ENV HDFS_CONF_dfs_namenode_name_dir=file:///hadoop/dfs/name
RUN mkdir -p /hadoop/dfs/name
VOLUME /hadoop/dfs/name

ADD run.sh /run.sh
RUN chmod a+x /run.sh

EXPOSE 50070
EXPOSE 8020

CMD ["/run.sh"]
